Conventionally, an articulated robot arm mechanism is used in various fields such as an industrial robot. For example, the robot arm mechanism is provided with a linear extension and retraction joint in combination with other joints. An arm section constituting the linear extension and retraction joint includes, for example, a first connection piece string and a second connection piece string. The first connection piece string and the second connection piece string are stored in a storage section. When a motor rotates forward to drive the linear motion joint, the first connection piece string and the second connection piece string stored in the storage section are joined and sent out as a columnar body. When the motor rotates backward, the arm section is pulled back to the storage section, and the columnar body is separated into the first connection piece string and the second connection piece string to be stored in the storage section. In such a robot arm mechanism, the first connection piece string may collide against the second connection piece string in the storage section if no countermeasure is taken.